//
//  YDActivityManager.h
//  IngCard
//
//  Created by kf on 2017/9/8.
//  Copyright © 2017年 IngDan. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "YDActivity.h"


#define ACTIVITY [YDActivityManager sharedInstance]


typedef void(^SyncComplete)(BOOL success,
                            NSString* msg,
                            NSMutableArray<YDActivity *> *syncActivity,
                            NSMutableArray<YDContact *> *syncContacts);

@interface YDActivityManager : NSObject

//getMore接口
@property(nonatomic, strong) NSMutableArray<YDActivity *> *activities;
@property(nonatomic, assign) BOOL hasMore;

//Sync接口
@property(nonatomic, strong) NSMutableArray<YDActivity *> *syncActivities;
@property(nonatomic, strong) NSMutableArray<YDContact *> *syncContacts;
@property(nonatomic, strong) NSMutableArray<YDContact *> *addContacts;
@property(nonatomic, assign) BOOL beAdded;

+ (instancetype)sharedInstance;

//获取活动列表，一次5个
-(void) getMoreOnComplete:(void (^)(BOOL success, NSString* msg)) onComplete;

-(void) modify:(NSString *)activityID
          desc:(NSString *) desc
    OnComplete:(void (^)(BOOL success, NSString* msg)) onComplete;

-(void) sync:(NSMutableDictionary<NSString*,NSArray<NSString *>*> *) info
  OnComplete:(SyncComplete) onComplete;
@end
